using System;
using System.Data;
using System.Configuration;
using System.Data.SqlClient;
namespace time
{
    public class work_sql
    {
        public static void Main()
        {
            string connectionString = @"server=LC29QL33X\SQLEXPRESS;database=master;uid=sa;pwd=111111;";
            SqlConnection con = new SqlConnection(connectionString);
            SqlCommand com = new SqlCommand();

            string sql = "select top 100 * from [MSreplication_options]";

            com.Connection = con;
            com.CommandText = sql;
            SqlDataAdapter ada = new SqlDataAdapter();
            ada.SelectCommand = com;
            DataSet ds = new DataSet();
            ada.Fill(ds);
            com.Dispose();
            DataTable dt = new DataTable();
            dt = ds.Tables[0];

            Console.WriteLine(dt.Rows[0][0]);


        }
    }
}